//
//  NSCustomAlertView.h
//  MacDevTest
//
//  Created by lbxia on 2022/9/2.
//  Copyright © 2022 com.lbx. All rights reserved.
//

#import <Cocoa/Cocoa.h>



@interface NSCustomAlertView : NSView

/// 显示alertview
/// @param title title description
/// @param content content description
/// @param type type 1: 信息  2:警告  作用: UI左侧图标区分
/// @param cancel 取消
/// @param sure 确认
+ (void)showWithTitle:(NSString*)title
              content:(NSString*)content
                 type:(NSInteger)type
               cancel:(void(^)(void))cancel
                 sure:(void(^)(void))sure;

/// 显示alertview
/// @param title title description
/// @param content content description
/// @param type type 1: 信息  2:警告  左侧图标区分
/// @param buttonTitles buttonTitles 按钮标题, 布局按照最后的排列在最右边
/// @param defaultIdx  蓝色按钮在buttonTitles的索引(第一位为0)
/// @param action action description
+ (void)showWithTitle:(NSString*)title
              content:(NSString*)content
                 type:(NSInteger)type
               buttons:(NSArray<NSString*>*)buttonTitles
           defaultIdx:(NSInteger)defaultIdx
               action:(void(^)(NSInteger idx, NSString *title))action;

@end


